<?php
// +----------------------------------------------------------------------
// | ThinkPHP [ WE CAN DO IT JUST THINK ]
// +----------------------------------------------------------------------
// | Copyright (c) 2006~2018 http://thinkphp.cn All rights reserved.
// +----------------------------------------------------------------------
// | Licensed ( http://www.apache.org/licenses/LICENSE-2.0 )
// +----------------------------------------------------------------------
// | Author: liu21st <liu21st@gmail.com>
// +----------------------------------------------------------------------
Route::get('/article/index$', 'Article/index');
Route::get('/article/:id$', 'Article/read')->pattern(['id' => '\d+']);
Route::get('/article/list_:id$', 'Article/listing')->pattern(['id' => '\d+']);
Route::get('/article/:route_name$', 'Article/listing')->pattern(['route_name' => '\w+']);
Route::get('/:route_name$', 'Page/read')->pattern(['route_name' => '\w+']);

return [
    // 首页
    '/'                           => 'Index/index',
    // 文章
    '/article/'                   => 'Article/index',
    // 手册
    '/manual/'                    => 'Manual/index',
    '/manual/index$'              => 'Manual/index',
    '/manual/list_:id$'           => 'Manual/listing',
    '/manual/:route_name$'        => 'Manual/read',
    '/manual/:route_name/content' => 'Manual/project',
	'/manual/:route_name/:id'     => 'Manual/content',
    // 搜索
	'/search'                     => 'Search/index',
    // tag搜索
    '/tag/:tag_name'              => 'Search/tag',
];
